import processing.core.*;
import processing.xml.*;

public class Test extends PApplet {

	  public void setup() {
		  PImage image1;
		  image1=loadImage("/media/win/Users/Steven/Pictures/Fotos/10.jpg");
		  int H=image1.height;
		  int W=image1.width;
		  int T=H*W;
		  
		  int Th=getT(T,H,W);
		  int Tw=getT(T,W,H);
		  
		  System.out.println(Th+" "+Tw);
		  

	  }

	  public int getT(int a, int b, int c){
		  int x=0;
		  x=(a*b)/c;
		  x=(int) sqrt(x);
		  return x;
	  }
	}